<template>
  <!-- 单击放这里 -->
  <view class="search">
    <u-search
      v-model="keyword"
      placeholder="请输入搜索关键字"
      @search="goSearch"
      @custom="goSearch"
      :height="'56rpx'"
      :searchIconSize="'44rpx'"
      :showAction="false"
      actionText="搜索"></u-search>
  </view>
</template>

<script>
export default {
  data() {
    return {
      keyword: ''
    }
  },
  methods: {
    // 跳转到搜索页面
    goSearch() {
      uni.navigateTo({
        url: `/sub_common/search/index?keyword=${this.keyword}`
      })
    }
  },
  created() {

  },
  mounted() {
  },
}
</script>

<style scoped lang="scss">
.search {
  padding: 10rpx 20rpx;
}
</style>
